/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package livroguiaestudo.capitulo02;

/**
 *
 * @author menandro.neto
 */
public class Plant {
    String getName() {
        return "plant";
    }
    Plant getType(){
        return this;
    }
}


class Flower extends Plant {
    /*

    Flower getType() {
        return this;
    }
     */

    //String getType() {return "this";}
    //Plant getType() {return this;}
    Tulip getType(){ return new Tulip(); }
}

class Tulip extends Flower {

}